package com.cloudeye.monitor.web.vo;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;

/**
 * @Description: ClassDescription
 * @Author: Zengzhihong
 * @Date: Create at 2018/3/23 14:08
 */
public class BootstrapTableVO<T> implements Serializable {

    private static final long serialVersionUID = 1360133467962023948L;
    /**
     * 总记录数
     */
    private int total = 0;

    /**
     * 当前分页（从1开始）
     */
    private int pageNo = 1;

    /**
     * 分页大小
     */
    private int pageSize = 10;
    /**
     * 共多少页
     */
    private int totalPage= 0;

    /**
     * 当前分页中包含的记录列表
     */
    private List<T> rows = new ArrayList<T>();

    /**
     * 构造函数
     */
    public BootstrapTableVO() {
        super();
    }

    /**
     * 构造函数
     */
    public BootstrapTableVO(int total, int currentPage, int totalPage, int pageSize, List<T> rows) {
        super();
        this.total = total;
        this.pageNo = currentPage;
        this.totalPage = totalPage;
        this.pageSize = pageSize;
        this.rows = rows;
    }

    public int getTotal() {
        return total;
    }

    public void setTotal(int total) {
        this.total = total;
    }

    public int getPageNo() {
        return pageNo;
    }

    public void setPageNo(int pageNo) {
        this.pageNo = pageNo;
    }

    public int getTotalPage() {
        return totalPage;
    }

    public void setTotalPage(int totalPage) {
        this.totalPage = totalPage;
    }


    public List<T> getRows() {
        return rows;
    }

    public void setRows(List<T> rows) {
        this.rows = rows;
    }

    public int getPageSize() {
        return pageSize;
    }

    public void setPageSize(int pageSize) {
        this.pageSize = pageSize;
    }

}
